//
//  StyleCollectionViewCell.m
//  OneDay
//
//  Created by lanou3g on 15/10/27.
//  Copyright © 2015年 oneDay. All rights reserved.
//

#import "StyleCollectionViewCell.h"

@implementation StyleCollectionViewCell

- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        CGFloat kW = self.frame.size.width;
        CGFloat kH = self.frame.size.height;
        
        self.layer.borderWidth = 0.1;
        self.layer.cornerRadius = self.frame.size.width / 20;
        self.backgroundColor = [UIColor colorWithRed:45 / 255.0 green:19 / 255.0 blue:19 / 255.0 alpha:0.8];
        
        UIView *view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 0.95 * kW, 0.95 * kH)];
        view.layer.cornerRadius = view.width / 20;
        
        view.backgroundColor = [UIColor colorWithRed:230 / 255.0 green:201 / 255.0 blue:115 / 255.0 alpha:1];
        [self.contentView addSubview:view];
        
        self.label = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, kW, kH)];
        self.label.font = [UIFont systemFontOfSize:12];
        self.label.textColor = [UIColor blackColor];
        self.label.layer.cornerRadius = self.label.frame.size.width / 20;
        self.label.textAlignment = NSTextAlignmentCenter;
        [self.contentView addSubview:self.label];
    }
    return self;
}


@end
